<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Assimp: Build using CMake</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">Assimp
   &#160;<span id="projectnumber">v3.0 (July 2012)</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.1.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">Build using CMake </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><h1><a class="anchor" id="cmake_intro"></a>
Introduction</h1>
<p>CMake is a cross-platform build system that is supported by assimp. CMake doesn't build on its own, instead it generates platform-specific build files for one of the build systems available on the system (i.e. on linux, it will typically be used to generate gnu makefiles).</p>
<p><b>If you know CMake already, you can skip over this page. Building assimp with CMake works like any other CMake build. </b></p>
<h1><a class="anchor" id="cmake_howto"></a>
Build using the GUI (Windows)</h1>
<div class="image">
<img src="cmake1.png" alt="cmake1.png"/>
</div>
<ul>
<li>Download the latest CMake from <a href="http://www.cmake.org/">http://www.cmake.org/</a> and install it</li>
<li>Run CMake GUI (at the time of this writing, its called cmake-gui.exe on Windows and appears in the start menu after installation)</li>
<li>Point it to the location of the assimp source code. The UI should now look like the screenshot above</li>
<li>Also point it to the folder where you want the binaries to be placed in.</li>
<li>Lines marked in red mark settings you haven't confirmed yet, so check if everything is fine and press "Configure" again (if you rebuild assimp later, only changed or newly added settings will appear in red since the last build settings are cached by CMake!)</li>
<li>Press "Generate" and pick a suitable output build system</li>
<li>Open the generated solution/project files and have fun</li>
</ul>
<h1><a class="anchor" id="cmake_howto_other"></a>
Build without GUI (Other)</h1>
<ul>
<li>Install CMake through the package manager of your choice, or grab a copy from <a href="http://www.cmake.org/">http://www.cmake.org/</a></li>
<li>Navigate to the folder where assimp's top level <em>CMakeLists.txt</em> resides</li>
<li>Use <pre class="fragment">cmake -DNAME_OF_SETTING=VALUE </pre> to configure the build (see the CMake file for a list of all configurable settings.</li>
<li>Use <pre class="fragment">cmake -G 'Unix Makefiles' </pre> to generate build files (GNU make in this case, for a full list of targets see the CMake docs).</li>
<li>Press "Generate" and pick a suitable output build system (i.e. vc version)</li>
<li>Build</li>
</ul>
<h1><a class="anchor" id="cmake_troubleshooting"></a>
Troubleshooting</h1>
<ul>
<li>Configure/Generate fails due to boost? Set the <pre class="fragment">ENABLE_BOOST_WORKAROUND </pre> flag.</li>
<li>Build problems with vc10 on Windows? Set the <pre class="fragment">VC10_STDINT_FIX </pre> build flag (may or may not be required) </li>
</ul>
</div></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Tue Jul 10 2012 17:55:53 for Assimp by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.1.1
</small></address>
</body>
</html>
